'''
infors = [{"name":"zhangsan","age":18},{"name":"lisi","age":19},{"name":"laowang","age":17}]
infors.sort(key=lambda x:x["age"])
print(infors)


def test(a,b,func):
    result = func(a,b)
    return result

func_new = input("请输入一个匿名函数")
func_new = eval(func_new)
num = test(2,3,func_new)
#num = test(2,3,lambda x,y:x+y)
print(num)

#交换两个值
#第一种
a = 1
b = 2
c = 0

c = a
a = b
b = c
#第二种
a = 2
b = 3

a = a + b
b = a - b
a = a - b
#第三种
a = 3
b = 4

a,b = b,a
'''
#对比这几个

#1
a = 100
def test(num):
    num+=num
    print(num)

test(a)
print(a)
print("*"*50)

#2
a = [100]
def test(num):
    num+=num
    print(num)

test(a)
print(a)
print("*"*50)

#3
a = [100]
def test(num):
    num = num + num
    print(num)

test(a)
print(a)
print("*"*50)







